<template>
  <div id="app">
    <router-view/>
    <Footbar v-if="flag" />
  </div>
</template>
<script>
import Footbar from '@/components/footbar.vue'
export default {
  data() {
    return {
      flag:true
    }
  },
  watch: {
    $route:{
      handler(n,o){
        this.flag= n.meta.flag
      },
      deep:true,
      immediate:true
    }
  },
  components:{
    Footbar
  }
}
</script>
<style lang="scss">
@import '~@/assets/reset.css';
.router-link-active{
  color:red;
}
</style>
